﻿<UserControl x:Class="FontPathSample.Page"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:brg="clr-namespace:BlueRoseGames.Controls.Text;assembly=BlueRoseGames.Controls.Text"
    Width="640" Height="480">
    <Canvas x:Name="LayoutRoot" Background="Black">
        <Canvas.RenderTransform>
            <ScaleTransform ScaleX="1" ScaleY="1"/>
        </Canvas.RenderTransform>
        <brg:PathTextBlock x:Name="tb" Font="JellyBelly70.xfn" Stroke="Red" Fill="White" StrokeThickness="2" FontSize="100" UpdateInterval="0:0:0.02">
            <brg:PathTextBlock.TextTransform>
                <brg:TransformGroup>
                    <brg:SineTransform StartAngle="0" Amplitude="30" Period="250"/>
                    <brg:PolarTransform Angle="180" CenterX="320" CenterY="240" RadiusX="250" RadiusY="200" RadiusStretch="1.2" AngleStretch=".4" TextDirection="Clockwise"/>
                    <brg:PerspectiveTransform AngleX="5" CameraX="320" CameraY="240" CameraZ="240" AngleY="12" />
                </brg:TransformGroup>
            </brg:PathTextBlock.TextTransform>
        </brg:PathTextBlock>
        <!--		<TextBlock Text="ABCDEFGHIJKLMNOPQRSTUVWXYZ" FontSize="48" Foreground="Red" FontFamily="/jellybelly.ttf#JellyBelly"/>
        -->
        <Ellipse x:Name="camera" Height="5" Width="5" Stroke="White" StrokeThickness="1" Canvas.Left="{Binding CameraX, Mode=TwoWay}" Canvas.Top="{Binding CameraY, Mode=TwoWay}">
            <Ellipse.RenderTransform>
                <TranslateTransform X="-2" Y="-2" x:Name="cameraTransform" />
            </Ellipse.RenderTransform>
        </Ellipse>
    </Canvas>
</UserControl>
